import tesserocr
from PIL import Image
image_to_parse=Image.open("test.png")
image_to_convert=image_to_parse.convert('L')
threshold=190
chart=[]
for i in range(256):
    if i<threshold:
        chart.append(0)
    else:
        chart.append(1)
image_for_threshold=image_to_convert.point(chart,'1')
image_for_threshold.show()
text_result=tesserocr.image_to_text(image_for_threshold)
print(text_result)